﻿using System;
using System.Collections.Generic;
using ConceptsFramework.AbstractConceptElements;
using ConceptsFramework.DerivedRelationships;

namespace PatternExplorer.DerivedConcepts
{
    public class MethodSummary : AbstractBindableConcept, IEquatable<MethodSummary>
    {

        /// <summary>
        /// Summary of IL code calling external methods in the current method
        /// </summary>
        public List<string> MethodsExternalCallsILCode
        {
            get; set;
        }

        public bool Equals(MethodSummary other)
        {
            return (this.Name == other.Name);
        }

      
        public override bool IsRelationshipAutorized<T>()
        {
            Type genericType = typeof(T);
            if (typeof(IsContainedRelationship).IsAssignableFrom(genericType))
                return true;
            return false;
        }

        public override void ResolveInverseRelationships()
        {
            
        }


        public string ReturnTypeName
        {
            get;
            set;
        }

        public bool IsVoidMethod
        {
            get;
            set;
        }

        public bool IsPublicMethod
        {
            get;
            set;
        }

        public bool IsStaticMethod
        {
            get;
            set;
        }
    }
}
